package com.yh.service;

import com.sun.javafx.binding.StringFormatter;
import org.apache.ibatis.annotations.Insert;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Select;
import com.yh.model.Admin;
import org.springframework.stereotype.Service;

import java.util.Map;

/**
 * Created by YH on 2017/8/28.
 */

public interface AdminService {

    /**
     * 用户信息查询
     * @param userName
     * @return
     */
    Admin findByName(String userName);


    /**
     * 用户名及密码登录
     * @param userName
     * @param password
     * @return
     */
    Admin findByNameAndPassword(String userName,String password);

    /**
     * 添加管理员
     * @param userName
     * @param password
     * @return
     */
    int addAdminUser(String userName,String password);
}
